package com.wcl.demo.model.entity;

import android.database.sqlite.SQLiteDatabase;

import java.util.Map;

import de.greenrobot.dao.AbstractDao;
import de.greenrobot.dao.AbstractDaoSession;
import de.greenrobot.dao.identityscope.IdentityScopeType;
import de.greenrobot.dao.internal.DaoConfig;

import com.wcl.demo.model.entity.User;
import com.wcl.demo.model.entity.Mp3Info;
import com.wcl.demo.model.entity.UserInfor;
import com.wcl.demo.model.entity.InviteMessages;
import com.wcl.demo.model.entity.InviteMessage;
import com.wcl.demo.model.entity.AroundInfor;
import com.wcl.demo.model.entity.BackGroundData;
import com.wcl.demo.model.entity.NoteBgData;
import com.wcl.demo.model.entity.CanSendData;

import com.wcl.demo.model.entity.UserDao;
import com.wcl.demo.model.entity.Mp3InfoDao;
import com.wcl.demo.model.entity.UserInforDao;
import com.wcl.demo.model.entity.InviteMessagesDao;
import com.wcl.demo.model.entity.InviteMessageDao;
import com.wcl.demo.model.entity.AroundInforDao;
import com.wcl.demo.model.entity.BackGroundDataDao;
import com.wcl.demo.model.entity.NoteBgDataDao;
import com.wcl.demo.model.entity.CanSendDataDao;

// THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT.

/**
 * {@inheritDoc}
 * 
 * @see de.greenrobot.dao.AbstractDaoSession
 */
public class DaoSession extends AbstractDaoSession {

    private final DaoConfig userDaoConfig;
    private final DaoConfig mp3InfoDaoConfig;
    private final DaoConfig userInforDaoConfig;
    private final DaoConfig inviteMessagesDaoConfig;
    private final DaoConfig inviteMessageDaoConfig;
    private final DaoConfig aroundInforDaoConfig;
    private final DaoConfig backGroundDataDaoConfig;
    private final DaoConfig noteBgDataDaoConfig;
    private final DaoConfig canSendDataDaoConfig;

    private final UserDao userDao;
    private final Mp3InfoDao mp3InfoDao;
    private final UserInforDao userInforDao;
    private final InviteMessagesDao inviteMessagesDao;
    private final InviteMessageDao inviteMessageDao;
    private final AroundInforDao aroundInforDao;
    private final BackGroundDataDao backGroundDataDao;
    private final NoteBgDataDao noteBgDataDao;
    private final CanSendDataDao canSendDataDao;

    public DaoSession(SQLiteDatabase db, IdentityScopeType type, Map<Class<? extends AbstractDao<?, ?>>, DaoConfig>
            daoConfigMap) {
        super(db);

        userDaoConfig = daoConfigMap.get(UserDao.class).clone();
        userDaoConfig.initIdentityScope(type);

        mp3InfoDaoConfig = daoConfigMap.get(Mp3InfoDao.class).clone();
        mp3InfoDaoConfig.initIdentityScope(type);

        userInforDaoConfig = daoConfigMap.get(UserInforDao.class).clone();
        userInforDaoConfig.initIdentityScope(type);

        inviteMessagesDaoConfig = daoConfigMap.get(InviteMessagesDao.class).clone();
        inviteMessagesDaoConfig.initIdentityScope(type);

        inviteMessageDaoConfig = daoConfigMap.get(InviteMessageDao.class).clone();
        inviteMessageDaoConfig.initIdentityScope(type);

        aroundInforDaoConfig = daoConfigMap.get(AroundInforDao.class).clone();
        aroundInforDaoConfig.initIdentityScope(type);

        backGroundDataDaoConfig = daoConfigMap.get(BackGroundDataDao.class).clone();
        backGroundDataDaoConfig.initIdentityScope(type);

        noteBgDataDaoConfig = daoConfigMap.get(NoteBgDataDao.class).clone();
        noteBgDataDaoConfig.initIdentityScope(type);

        canSendDataDaoConfig = daoConfigMap.get(CanSendDataDao.class).clone();
        canSendDataDaoConfig.initIdentityScope(type);

        userDao = new UserDao(userDaoConfig, this);
        mp3InfoDao = new Mp3InfoDao(mp3InfoDaoConfig, this);
        userInforDao = new UserInforDao(userInforDaoConfig, this);
        inviteMessagesDao = new InviteMessagesDao(inviteMessagesDaoConfig, this);
        inviteMessageDao = new InviteMessageDao(inviteMessageDaoConfig, this);
        aroundInforDao = new AroundInforDao(aroundInforDaoConfig, this);
        backGroundDataDao = new BackGroundDataDao(backGroundDataDaoConfig, this);
        noteBgDataDao = new NoteBgDataDao(noteBgDataDaoConfig, this);
        canSendDataDao = new CanSendDataDao(canSendDataDaoConfig, this);

        registerDao(User.class, userDao);
        registerDao(Mp3Info.class, mp3InfoDao);
        registerDao(UserInfor.class, userInforDao);
        registerDao(InviteMessages.class, inviteMessagesDao);
        registerDao(InviteMessage.class, inviteMessageDao);
        registerDao(AroundInfor.class, aroundInforDao);
        registerDao(BackGroundData.class, backGroundDataDao);
        registerDao(NoteBgData.class, noteBgDataDao);
        registerDao(CanSendData.class, canSendDataDao);
    }
    
    public void clear() {
        userDaoConfig.getIdentityScope().clear();
        mp3InfoDaoConfig.getIdentityScope().clear();
        userInforDaoConfig.getIdentityScope().clear();
        inviteMessagesDaoConfig.getIdentityScope().clear();
        inviteMessageDaoConfig.getIdentityScope().clear();
        aroundInforDaoConfig.getIdentityScope().clear();
        backGroundDataDaoConfig.getIdentityScope().clear();
        noteBgDataDaoConfig.getIdentityScope().clear();
        canSendDataDaoConfig.getIdentityScope().clear();
    }

    public UserDao getUserDao() {
        return userDao;
    }

    public Mp3InfoDao getMp3InfoDao() {
        return mp3InfoDao;
    }

    public UserInforDao getUserInforDao() {
        return userInforDao;
    }

    public InviteMessagesDao getInviteMessagesDao() {
        return inviteMessagesDao;
    }

    public InviteMessageDao getInviteMessageDao() {
        return inviteMessageDao;
    }

    public AroundInforDao getAroundInforDao() {
        return aroundInforDao;
    }

    public BackGroundDataDao getBackGroundDataDao() {
        return backGroundDataDao;
    }

    public NoteBgDataDao getNoteBgDataDao() {
        return noteBgDataDao;
    }

    public CanSendDataDao getCanSendDataDao() {
        return canSendDataDao;
    }

}
